Skip to content

feat: add es2026 as a valid target and lib - #64096

Merged
Daniel Rosenwasser (DanielRosenwasser) merged 27 commits into
microsoft:mainfrom
a-tarasyuk:feat/63704
Sep 28, 2026
Merged

Daniel Rosenwasser (DanielRosenwasser) merged 27 commits into
microsoft:mainfrom
a-tarasyuk:feat/63704

Conversation

@a-tarasyuk

Copy link
Copy Markdown
Contributor

Fixes #63704

@typescript-automation typescript-automation Bot added the For Milestone Bug PRs that fix a bug with a specific milestone label Aug 30, 2026
@a-tarasyuk
Oleksandr Tarasiuk (a-tarasyuk) marked this pull request as ready for review August 31, 2026 21:27
Copilot AI balanced review requested due to automatic review settings August 31, 2026 21:27

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds ES2026 compiler-target and standard-library support, including the APIs requested by #63704.

Changes:

  • Registers es2026 as a target, default standard target, and library.
  • Adds ES2026 API declarations and preserves esnext.* aliases.
  • Adds conformance tests and refreshes generated baselines.

Reviewed changes

Copilot reviewed 136 out of 540 changed files in this pull request and generated no comments.

Show a summary per file
File Description
packages/typescript/src/enums/scriptTarget*.ts Exposes ES2026 publicly.
packages/typescript/test/{async,sync}/api.test.ts Updates target diagnostics.
tsc/internal/core/{compileroptions,scripttarget_stringer_generated}.go Defines and formats the target.
tsc/internal/tsoptions/enummaps.go Registers target, libraries, and compatibility aliases.
tsc/internal/transformers/estransforms/definitions.go Selects the ES2026 transform pipeline.
tsc/internal/checker/utilities.go Adds ES2026 library suggestions.
tsc/internal/bundled/libs/lib.es2026*.d.ts Defines the ES2026 library and APIs.
tsc/internal/bundled/libs/lib.esnext.d.ts Makes ESNext inherit ES2026.
tsc/internal/bundled/{embed_generated,libs_generated}.go Embeds and registers new libraries.
tsc/internal/compiler/program_test.go Updates expected ESNext library ordering.
tsc/testdata/fixtures/compiler/*.ts Synchronizes compiler fixtures.
tsc/testdata/tests/cases/conformance/es2026/*.ts Tests ES2026 APIs and diagnostics.
tsc/testdata/baselines/reference/** Refreshes generated compiler, build, watch, API, and conformance baselines.

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

@jakebailey
Jake Bailey (jakebailey) requested a balanced review from Copilot September 4, 2026 17:54
Comment thread tsc/internal/bundled/libs/lib.es2026.error.d.ts Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

The public target and library surface spans hundreds of generated baselines and warrants final human validation against the ES2026 specification.

Review details
  • Files reviewed: 136/540 changed files
  • Comments generated: 0 new
  • Review effort level: Balanced

Comment thread tsc/internal/bundled/libs/lib.es2026.full.d.ts
Comment thread tsc/internal/bundled/libs/lib.es2026.json.d.ts Outdated
Comment thread tsc/internal/bundled/libs/lib.es2026.typedarrays.d.ts
Comment thread tsc/testdata/fixtures/compiler/commandLineParser.ts

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The jsonRawJSON2 source and checked-in baselines disagree, causing baseline tests to fail.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Review details
  • Files reviewed: 146/553 changed files
  • Comments generated: 1
  • Review effort level: Balanced

Comment thread tsc/testdata/tests/cases/conformance/es2026/jsonRawJSON2.ts
@typescript-automation

Copy link
Copy Markdown
Contributor

Daniel Rosenwasser (@DanielRosenwasser) Here are the results of running the user tests with tsc comparing main and refs/pull/64096/merge:

There were infrastructure failures potentially unrelated to your change:

  • 1 instance of "Git clone failed"
  • 1 instance of "Package install failed"

Otherwise...

Something interesting changed - please have a look.

Details

lodash

/mnt/vss/work/1/s/ts_downloads//m/lodash/tsconfig.json

  • [MISSING] error TS2345: Argument of type '{ castArray: () => any[]; clone: (value: any) => any; cloneDeep: (value: any) => any; cloneDeepWith: (value: any, customizer?: Function | undefined) => any; cloneWith: (value: any, customizer?: Function | undefined) => any; ... 50 more ...; toString: (value: any) => string; }' is not assignable to parameter of type 'string'.
    • /mnt/vss/work/1/s/ts_downloads//m/lodash/node_modules/lodash/fp/lang.js(2,26)

@typescript-automation

Copy link
Copy Markdown
Contributor

Daniel Rosenwasser (@DanielRosenwasser) Here are the results of running the top 400 repos with tsc comparing main and refs/pull/64096/merge:

Everything looks good!

@typescript-automation

Copy link
Copy Markdown
Contributor

Hey Daniel Rosenwasser (@DanielRosenwasser), the results of running the DT tests are ready.

Everything looks the same!

You can check the log here.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The target, libraries, API surface, and conformance coverage are coherent; only a non-blocking JSDoc typo remains.

Review effort: Balanced
Findings: None

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The target registration, library declarations, API exposure, and corresponding baselines are consistent and adequately tested.

Review effort: Balanced
Findings: None

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

Target registration, library declarations, compatibility mappings, and conformance coverage are consistent.

Review effort: Balanced
Findings: None

@jakebailey Jake Bailey (jakebailey) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we typically add a slew of tests for lib files but, it's fine

@DanielRosenwasser

Copy link
Copy Markdown
Member

I am happy to have lib tests to be honest.

Separately, it looks like we have some baseline merge conflicts though.

Merged via the queue into microsoft:main with commit 75e50a4 Sep 28, 2026
29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

For Milestone Bug PRs that fix a bug with a specific milestone

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add es2026 as valid target and lib

4 participants